﻿using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Media;

namespace Toon.Controls
{
	public class DetailRegion : Button
	{
		public DetailRegion()
		{
			Background = new SolidColorBrush(Colors.White);
			DefaultStyleKey = typeof(DetailRegion);
			MouseEnter += AddBorder;
			MouseLeave += RemoveBorder;
			MouseLeftButtonUp += RemoveBorder;

		}

		void RemoveBorder(object sender, MouseEventArgs e)
		{
			VisualStateManager.GoToState(this, "Normal", false);
		}

		void AddBorder(object sender, MouseEventArgs e)
		{
			VisualStateManager.GoToState(this, "MouseOver", false);
		}
	}
}